<template>
<div class="main">
    <div class="wCenter">
        <div class="hTop">
            <van-nav-bar :title="title" left-text="返回首页" left-arrow @click-left="$router.replace({path:'/'})"/>
        </div>
        <div class="hBox">
             <router-view></router-view>
        </div>
    </div>
    <Footer></Footer>
</div>
</template>
<script>
import Footer from '@/components/Footer'
export default {
    components:{
        Footer
    },
    computed:{
        title(){
            return this.$route.meta.title
        }
    },
}
</script>

<style lang="scss" scoped>
@import "@/styles/variable.scss";
    .wCenter{
        position: relative;
    }
    .hTop{
        position: fixed;
        top:0;
        left:0;
        z-index: 2;
        width:100%;
    }
    .hBox{
        min-height: 80vh;
        margin-top: 48px;
        margin-bottom: 100px;
    }
</style>